<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>IE下设置p的innerHTML中包含p的时候报告未知的运行时错误</title>

</head>
<body>
	<p id="p1" style="width:100px;height:80px;background-color:lightblue;"></p>
	<script>
		
		document.getElementById("p1").innerHTML = "<p id='p2' style='background-color:lightgreen;'>--------</p>";
		//var errText = '"<a href="http://help.paipai.com/content/help_208.shtml?PTAG=1020.4.5" target="_blank" title="已加入诚信保证计划" tag="chengbao" style="margin:0;"><span class="chengbao" style="display: -moz-inline-stack;display: inline-block;zoom:1;*display: inline;margin-right:10px;margin-left:0px;margin-top:0px;margin-bottom:0px;background:url(http://static.paipaiimg.com/assets/common/ppicons.png?t=20091210) no-repeat;outline:none;font-size:0px;vertical-align: middle;cursor:pointer;width:16px;height:16px;background-position:-80px -345px;"></span></a><a href="http://www.paipai.com/trust/chengbao.shtml?tab=2&PTAG=30072.4.6#1" target="_blank" title="已加入诚信保证计划，卖家承诺在买家收货后7天内可无理由退换货。" tag="sevenship" style="margin:0;"><span class="sevenship" style="display: -moz-inline-stack;display: inline-block;zoom:1;*display: inline;margin-right:5px;margin-left:0px;margin-top:0px;margin-bottom:0px;background:url(http://static.paipaiimg.com/assets/common/ppicons.png?t=20091210) no-repeat;outline:none;font-size:0px;vertical-align: middle;cursor:pointer;width:16px;height:16px;background-position:-20px -345px;"></span></a>"';
		//document.getElementById("p1").innerHTML = errText;
	</script>
	<div>
		据MS官方说，用js插入HTML的方式（innerHTML）的时候，在IE下，如果是给tr/table/tbody/frameset/title/col/columgroup等标签的时候会报告“未知的运行时错误”这个错误，但是现在看来，往一个P里面插入P的时候也会出现这样的错误。
	</div>
</body>
</html>
